﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Inapplicable.aspx.cs" Inherits="PPAP.Web.Part.Inapplicable" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<html>
<head>
    <title>CreatPPAR</title>
    <script language="javascript">
        function add() {
            url = "PPAPTasksEdit.aspx";
            PopUpWindow(url, 400, 150, 580, 400);
        }
        function edit(id) {
            url = "InapplicableSet.aspx?type=1&RID=" + id;
            // window.open(url, 'newwindow', 'left=200,top=60,width=970,height=600, toolbar=no, menubar=no, scrollbars=yes, resizable=no,location=no, status=no');
            PopUpWindow(url, 230, 60, 920, 550);
            //		        window.location.href = url;
        }
    </script>
</head>
<body style="font-family: Arial, Helvetica, sans-serif;">
    <form id="Form1" method="post" runat="server">
    <font size='-1' color='gray'>Current position:To do list>>PART release</font>
    <table cellspacing="0" cellpadding="0" width="100%" align="center" border="0">
        <tr>
            <td>
                <asp:DataGrid ID="dgList" HeaderStyle-BackColor="#E7E8E8" HeaderStyle-Font-Bold="true"
                    HeaderStyle-Height="32px" Width="100%" AllowSorting="true" OnLoad="dgLoad" AutoGenerateColumns="False"
                    runat="server" onsortcommand="dgList_SortCommand">
                    <Columns>
                        <asp:BoundColumn DataField="rownum" HeaderText="No." FooterText="No.">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                         <asp:BoundColumn DataField="bdntpartno" SortExpression="bdntpartno" HeaderText="Part No." FooterText="Part No.">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="bdntpartname" SortExpression="bdntpartname" HeaderText="Part name" FooterText="Part name">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="color" SortExpression="color" HeaderText="Color" FooterText="Color">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="pparno" SortExpression="pparno" HeaderText="PPAR No." FooterText="PPAR No.">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="bdntrevisionno" SortExpression="bdntrevisionno" HeaderText="Revision No." FooterText="Revision No.">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                         <asp:TemplateColumn HeaderText="Planned PPAP date" FooterText="Planned PPAP date" SortExpression="planedppardate">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                            <ItemTemplate>
                                <asp:Label ID="Label8" runat="server" Text='<%#Eval("planedppardate").ToString()==""?"":DateTime.Parse(Eval("planedppardate").ToString()).ToString("yyyy-MM-dd")  %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateColumn>
                        <asp:BoundColumn DataField="suppliername" SortExpression="suppliername" HeaderText="Supplier name" FooterText="Supplier name">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="supplieradmin" SortExpression="supplieradmin" HeaderText="Supplier admin" FooterText="Supplier admin">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:BoundColumn>
                        <asp:HyperLinkColumn Visible="false" Text="Edit" DataNavigateUrlField="ID" DataNavigateUrlFormatString="javascript:edit('{0}')"
                            HeaderText="Action">
                            <ItemStyle HorizontalAlign="Left"></ItemStyle>
                        </asp:HyperLinkColumn>
                        <asp:TemplateColumn  ItemStyle-HorizontalAlign="Left" FooterText="Action" HeaderStyle-HorizontalAlign="Left" >
                            <HeaderTemplate>
                                Action
                            </HeaderTemplate>
                            <ItemTemplate>
                                <asp:ImageButton ID="ImageButton1" ToolTip='View' PostBackUrl=<%# "javascript:edit('"+Eval("ID")+"')" %>
                                    ImageUrl='<%# ShowImage(Eval("status").ToString()) %>' runat="server" />
                            </ItemTemplate>
                        </asp:TemplateColumn>
                    </Columns>
                    <HeaderStyle BackColor="#E7E8E8" Font-Bold="True" Height="32px"></HeaderStyle>
                </asp:DataGrid>
            </td>
        </tr>
        <tr>
            <td align="center">
                <webdiyer:AspNetPager ID="AspNetPager2" runat="server" Width="100%" CssClass="paginator"
                    ShowPageIndexBox="Always" PageIndexBoxType="DropDownList" TextBeforePageIndexBox="goto"
                    HorizontalAlign="Center" PageSize="20" EnableTheming="true" AlwaysShow="True"
                    FirstPageText="|&lt;" LastPageText="&gt;|" NextPageText="&gt;" PrevPageText="&lt;"
                    SubmitButtonText="Go" TextAfterPageIndexBox="page" InvalidPageIndexErrorMessage="Page index is not effective numerical！"
                    OnPageChanged="AspNetPager2_PageChanged" PageIndexOutOfRangeErrorMessage="Page index beyond range"
                    BackColor="#E7E8E8">
                </webdiyer:AspNetPager>
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
